package com.ltmonitor.entity;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;

/**
 * 
 * @author DELL
 * 报警参数配置，配置某一类型的报警，是否启动，是否弹窗，是否有声音，是否统计起止时间
 */

@Entity
@Table(name="AlarmConfig")
@org.hibernate.annotations.Proxy(lazy = false)
public class AlarmConfig implements Serializable{
	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	@Column(name = "id", unique = true, nullable = false)
	private long entityId;
	/**
	 * 所属部门Id
	 */
	private long depId;
	
	/**
	 * 报警中文名称
	 */
	private String name;
	/**
	 * 报警类型 常量 来自 AlarmRecord中定义的常量
	 */
	private String alarmType;
	/**
	 * 报警来源 常量 来自 AlarmRecord中定义的常量
	 */
	private String alarmSource;
	/**
	 * 是否启动
	 */
	private boolean enabled;
	/**
	 * 是否播放报警声音
	 */
	private boolean soundEnabled;
	/**
	 * 是否弹窗
	 */
	private boolean popupEnabled;
	/**
	 * 是否统计报警的起止时间
	 */
	private boolean statisticEnabled;

	/**
	 * 当报警发生的时候，只报警一次，false，则一直报警直到报警关闭或取消
	 */
	private boolean alarmOnce;

	
	public  long getEntityId() {
		return entityId;
	}
	public  void setEntityId(long value) {
		entityId = value;
	}
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public String getAlarmType() {
		return alarmType;
	}
	public void setAlarmType(String alarmType) {
		this.alarmType = alarmType;
	}
	public String getAlarmSource() {
		return alarmSource;
	}
	public void setAlarmSource(String alarmSource) {
		this.alarmSource = alarmSource;
	}
	public boolean isEnabled() {
		return enabled;
	}
	public void setEnabled(boolean enabled) {
		this.enabled = enabled;
	}
	public boolean isSoundEnabled() {
		return soundEnabled;
	}
	public void setSoundEnabled(boolean soundEnabled) {
		this.soundEnabled = soundEnabled;
	}
	public boolean isPopupEnabled() {
		return popupEnabled;
	}
	public void setPopupEnabled(boolean popupEnabled) {
		this.popupEnabled = popupEnabled;
	}
	public boolean isStatisticEnabled() {
		return statisticEnabled;
	}
	public void setStatisticEnabled(boolean statisticEnabled) {
		this.statisticEnabled = statisticEnabled;
	}
	public long getDepId() {
		return depId;
	}
	public void setDepId(long depId) {
		this.depId = depId;
	}
}
